import request from '@/utils/request'

export function getSupplier(query) {
    return request({
        url: "/api/supplier/list",
        method: "POST",
        data: query
    })
}

export function getSupplierInfo(id) {
    return request({
        url: `/api/supplier/get/${id}`,
        method: "GET"
    })
}

export function deleteManySupplier(query) {
    return request({
        url: `/api/supplier/deleteIds`,
        method: "DElETE",
        data: query
    })
}

export function deleteSupplier(id) {
    return request({
        url: `/api/supplier/delete/${id}`,
        method: "DElETE"
    })
}

export function createSupplier(query) {
    return request({
        url: `/api/supplier/create`,
        method: "POST",
        data: query
    })
}

export function updateSupplier(query) {
    return request({
        url: `/api/supplier/update`,
        method: "PUT",
        data: query
    })
}